Release 10.1A: OpenEdge Development:
Progress 4GL Reference
INTEGER function
Converts an expression of any data type to an integer value, rounding that value if necessary.
Syntax
expressionA constant, field name, variable name, or expression whose value can be of any data type. If the value of
Exampleexpressionis character then it must be valid for conversion into a number (for example, “1.67" is valid, “1.x3" is not). Ifexpressionis logical, then the result is 0, ifexpressionis FALSE, and 1, ifexpressionis TRUE. Ifexpressionis a date, then the result is the number of days from 1/1/4713 B.C. to that day. If the value ofexpressionis the Unknown value (?), then the result is the Unknown value (?).This procedure takes the first word (that is, the substring that precedes the first space character) from the customer address and tries to convert it to an integer (street-number). If the conversion fails (for example, the first word contains non-numeric characters) the procedure displays an error message. Otherwise the cust-num, address, and converted street number are displayed.
See also
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |